package cn.tedu.oop;
/**本类用于面对对象第一天综合练习*/
public class TestOop {
    public static void main(String[] args) {
        Person p=new Person();
        p.setAddress("山东省菏泽市曹县牛逼666我的宝贝！");
        p.setAge(666);
        p.setGender("男人");
        p.setName("阿仁");
        p.setHeight(188.8);
        System.out.println(p.getName());
        System.out.println(p.getAge());
        System.out.println(p.getHeight());
        System.out.println(p.getGender());
        System.out.println(p.getAddress());
        p.eat();
    }
}
class Person{
   //特征，属性，成员变量
    private String name;
    private String gender;
    private double height;
    private String address;
    private int age;

    public void eat(){
        study();
        System.out.println("干饭人，干饭魂！");
        drink();
    }
    private void study(){
        System.out.println("一天不学习，我浑身难受");
    }
    private void drink(){
        System.out.println("喝水人，喝水魂！");
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public double getHeight() {
        return height;
    }

    public void setHeight(double height) {
        this.height = height;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
}